/*
 * @Author: Superficial
 * @Date: 2021-11-05 22:02:28
 * @LastEditTime: 2021-11-05 22:04:19
 * @Description:
 */

export const formatJSONString = (json: string, indent = 0): string => {
  const jsonString = json || ''
  return !jsonString.trim() ? '' : JSON.stringify(JSON.parse(jsonString), null, indent)
}
